<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <script type="text/javascript">
        if(self != top){top.location.href = self.location.href;}
    </script>
    <%--常量--%>
    <%@ include file="/common/constHead.jsp"%>
    <%--jQuery--%>
    <%@ include file="/common/jqueryHead.jsp"%>
    <%--jo--%>
    <%@ include file="/common/joHead.jsp"%>
    <%--bootstrap和字体--%>
    <%@ include file="/common/bootstrapHead.jsp"%>
    <%--layer--%>
    <%@ include file="/common/layerHead.jsp"%>
    <%--公共--%>
    <%@ include file="/common/commonHead.jsp"%>
    <title>登录</title>
    <link href="<%=URL_STATIC%>static/css/login.css" rel="stylesheet">
    <script type="text/javascript">
        $(function () {

        });
        function loginSubmit(){
            jo.showLoading();
            var account = $("#account").val();
            var password = $("#password").val();
            var redirectTo = jo.getUrlParam("redirectTo");//登录成功后重定向的地址
            jo.postAjax('{URL_UMS}login.action',{"account":account,"password":password,"redirectTo":redirectTo},function(json){
                if(json.code == 1 && json.redirectTo){
                    window.location.href = json.redirectTo;
                }else{
                    jo.alert(json.info);
                }

            });
            jo.showLoading(false);
        }
    </script>
</head>
<body class="" style="background-color: #26A8FA;">

<div class="container-fluid" style="height: 100%;">
    <div class="row">
        <div class="login-head" style="border-color: #DDDDDD;">
            <img src="<%=URL_STATIC%>static/images/login_logo2.png" class="login-logo" style="height: 40px;">
            <span style="color:white;font-size: 20px;vertical-align: middle;font-weight: bold;">检测实验室系统</span>
        </div>
    </div>
    <div class="row">
        <div class="col-lg-2"></div>
        <div class="col-lg-8">
            <div class="login-content">
                <div class="login-ad">

                </div>
                <div class="login-bar" style="background-color: #EEF3F7;border: white solid 1px;height: 340px;">
                    <span class="h4"><b>密码登录</b></span>
                    <br/><br/>
                    <h5 style="color: #73777A;">使用账号密码进行登录</h5>
                    <br/>
                    <input class="form-control" value="admin" id="account" name="account" placeholder="用户名" autocomplete="off" type="text">
                    <br/>
                    <input class="form-control" value="123456" id="password" name="password" placeholder="登录密码" autocomplete="off" type="password">
                    <br/>
                    <button type="button" class="btn btn-primary" style="width: 100%;" onclick="loginSubmit()">登录</button>

                    <%--<div class="hint">
                        <a href="#">忘记密码</a>
                        &nbsp;
                        <a href="#">免费注册</a>
                    </div>--%>
                    <%--<h6>其他方式登录：
                        <img class="login-other" title="微博授权登录" src="">
                        &nbsp;&nbsp;<img class="login-other" title="支付宝授权登录" src=""/>
                    </h6>--%>
                </div>
            </div>
        </div>
        <div class="col-lg-2"></div>
    </div>
</div>

<script src="<%=URL_STATIC%>static/plugin/bootstrap-3.3.7-dist/js/bootstrap.min.js"></script>
</body>
</html>
